]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
SwipeScroll: Only allow starting with the left button
authorAdel Gadllah <adel.gadllah@gmail.com>
Sat, 23 Apr 2011 07:45:58 +0000 (09:45 +0200)
committerAdel Gadllah <adel.gadllah@gmail.com>
Mon, 27 Jun 2011 15:08:25 +0000 (17:08 +0200)
Currently we allow starting swipe-scroll with any mouse button
which is weird from an UI pov and causes inconsistencies with
event handling.

https://bugzilla.gnome.org/show_bug.cgi?id=647186

js/ui/overview.js

index 9d4cad82a89481332de986ffc40d39bdabcace2d..ec67625445a6976826bebf93368d8f7075c56e7b 100644 (file)
@@ -281,7 +281,8 @@ Overview.prototype = {
     },
 
     _onButtonPress: function(actor, event) {
-        if (this._scrollDirection == SwipeScrollDirection.NONE)
+        if (this._scrollDirection == SwipeScrollDirection.NONE
+            || event.get_button() != 1)
             return;
 
         let [stageX, stageY] = event.get_coords();